package com.siyue.controller;

import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.apache.shiro.authz.annotation.RequiresRoles;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class HelloController {


    @RequestMapping("hello")
//    @RequiresPermissions("user")
    @RequiresRoles("user") //角色授权
    public String hello() {
        return "ok";
    }
}
